﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace EliteControls
{
	/// <summary>
	/// Interaction logic for UserControl1.xaml
	/// </summary>
	public partial class TradeRank : UserControl
	{
		private int rank = 0;
		private List<Image> icons = new List<Image>();
		public TradeRank()
		{
			this.InitializeComponent();
			this.icons = new List<Image>
			{
				this.rank1,this.rank2,this.rank3,this.rank4,this.rank5,this.rank6,this.rabk7,this.rank8,this.rank9
			};
			this.Rank = 0;
			
		}
		
		public int Rank
		{
			get
			{
				return this.rank;
			}
			set
			{
				this.rank = value;
				for(int i =0; i < this.icons.Count; i++)
				{
					if(this.rank != i)
					{
						this.icons[i].Visibility = 	Visibility.Hidden;
					} 
					else 
					{
						this.icons[i].Visibility = 	Visibility.Visible;
					}
				}
			}
		}
	}
}